<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>列表的直接渲染</title>
</head>
<body>
  <div id="root">
          <ul>
              <li v-for="(user,index) in users" :key="user.id">
                  {{user.name }}  ----  {{user.age}} ---{{age}}
              </li>
          </ul>
      <br>

  </div>


<script src="https://cdn.bootcdn.net/ajax/libs/vue/2.6.12/vue.js"></script>
<script>
Vue.config.productionTip = false

    new Vue({
        el:'#root',
        data:{
            users:[
                {id: 1, name: "Alice",age:12},
                {id: 2, name: "Jack",age:13},
                {id: 3, name: "Lucy",age:14},
                {id: 4, name: "Tom",age:15},
            ],
            nums:[4,1,6,7,0,9],
            age:12

        }
    })


</script>
</body>
</html>